import React from 'react';

import CommonSendFetchAction from '../common/CommonSendFetchAction';
import Constants from '../../common/Constants';

export default class LoginCheckVersionAction extends CommonSendFetchAction {
  constructor(props) {
    super(props);

    this.moduleType = Constants.MODULE_TYPE.LOGIN;
    this.name = "LoginCheckVersionAction";
  }

  _dealFinishSucess(data, response) {
    let detail = "";
    this.caller.setState({
      viewStatus:response.status,
      isResponeUpdate:true,
      statusText:detail,
      data:data,
    })
  }

  _dealFinishFailed(data, response) {
    let detail = "检测版本失败";
    this.caller.setState({
      viewStatus:response.status,
      statusText:detail + " " + response.status,
    })
  }
}
